<%= javascript_include_tag 'calendar.js' %>

<h1><%= @project.name %></h1>
<%= link_to('Edit project',:action=>:edit, :id => @project) %> |
<%= link_to('Tasks',:controller=>:task, :action=>:index, :id => @project) %> |
<%= link_to('Requirements',:controller=>:requirements, :action=>:index, :id => @project) %> (beta)

<h2>Calendar</h2>
<%= render(:partial=>'calendar/events', :locals=>{:msg=>''}) %>


<h2>Recently done tasks</h2>
In the last 24 jours
<ul style="list-style-type:none;padding:0;font-size:small;">
<%= render(:partial=>'task', :collection=>@tasksdone.select{|t| t.done_on!=nil and t.done_on + 1.day >= Date.today()}) %>
</ul>
Before
<ul style="list-style-type:none;padding:0;font-size:small;">
<%= render(:partial=>'task', :collection=>@tasksdone.select{|t| t.done_on!=nil and t.done_on + 1.day <= Date.today()}) %>
</ul>

<% if @notes.size > 0 -%>
  <h2>Notes</h2>
  <ul>
  <%= render(:partial=>'note', :collection=>@notes) %>
  </ul>
<% end -%>

